//
//  RESIDUE.h
//  ContactPDB
//
//  Created by Bertrand Caron on 29/08/12.
//  Copyright (c) 2012 __MyCompanyName__. All rights reserved.
// Un residue est un tableau d'atome
//

#import <Foundation/Foundation.h>
#import "ATOM.h"

@interface  RESIDUE : NSObject <NSCoding>

@property NSMutableArray*  res_array ;
@property NSString* res_name;

-(id) init :(NSMutableArray*) anArray:(NSString*) aString;
-(id) initWithSize :(int)aSize;
-(int)getAtomCount;
-(void) printResDescription:(int) i;

//Accessors
-(ATOM*) atomAtIndex:(int)anIndex;
-(void)updateAtomResidueCoordinates:(NSArray*) floatXYZArray;

+(NSMutableArray*) componentsSeparedBySpace:(NSString*)aString;
+(NSMutableArray*)componentsSeparatBySpaceCEQUIV2:(const char*)aChar;

+(char**) componentsSeparatByNewLineCEQUIV2:(const char*)aChar:(int*)numWord;

-(void)addAtomToArray:(ATOM*)anAtom;


//NScoding
-(void) encodeWithCoder:(NSCoder *)encoder;
-(id)initWithCoder:(NSCoder *)decoder ;
-(id)initWithEncodedFrame:(NSMutableArray*)array :(NSString*)name;


@end
